package com.zoe.service;

import com.zoe.dao.UserDao;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

/**
 * @Author Zoe
 * @Date: 2020/11/25
 * @Description
 */
@Service
public class UserService {
    @Autowired
    UserDao userDao;

    @Transactional()
    public int insert() {
        int update = userDao.insert();
        int i = 10 / 0;
        return update;
    }

    public void T1() {
        System.out.println(1);
        this.insert();
    }

}
